# Contributor: Justin Berthault <justin.berthault@zaclys.net>
# Maintainer: Justin Berthault <justin.berthault@zaclys.net>
pkgname=py3-mypy
pkgver=0.961
pkgrel=0
pkgdesc="Optional static typing for Python (PEP484)"
options="!check" # Tests fail on builders, pass on CI
url="https://mypy-lang.org/"
arch="noarch"
license="MIT"
depends="
	py3-mypy-extensions
	py3-tomli
	py3-typing-extensions
	"
makedepends="python3-dev py3-setuptools"
checkdepends="py3-pytest py3-pytest-xdist py3-lxml py3-virtualenv"
source="https://files.pythonhosted.org/packages/source/m/mypy/mypy-$pkgver.tar.gz"
builddir="$srcdir/"mypy-$pkgver

build() {
	python3 setup.py build
}

check() {
	rm -f \
		mypyc/test/test_analysis.py \
		mypyc/test/test_exceptions.py \
		mypyc/test/test_refcount.py \
		mypyc/test/test_run.py
	py.test-3 -v
}

package() {
	python3 setup.py install --prefix=/usr --root="$pkgdir"
}

sha512sums="
1056cf3c436f133c316604e837a9705fe12c4f7fa25ea4de396d8a6723b7a76be7ea04ceb6bcd05d62f013accb702601deb9ed8ea94bd0cdbb9cde5992178556  mypy-0.961.tar.gz
"
